package com.sky.mapper;

import com.github.pagehelper.Page;
import com.sky.annotation.AutoFill;
import com.sky.dto.SetmealPageQueryDTO;
import com.sky.entity.Setmeal;
import com.sky.enumeration.OperationType;
import com.sky.vo.DishItemVO;
import com.sky.vo.SetmealVO;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface UserSetmealMapper {


    //根据套餐id查询套餐
    SetmealVO selectById(Long id);

    //用户端根据分类id查询套餐
    @Select("select * from setmeal where category_id = #{categoryId} and status=1")
    List<Setmeal> selectByCategoryId(String categoryId);

    //根据套餐id查询对应的菜品集合
    List<DishItemVO> getDishBySetmealId(Long id);
}
